package cn.frontop.funswitch.service;

import cn.frontop.funswitch.entity.TokenEntity;
import com.baomidou.mybatisplus.extension.service.IService;
import io.swagger.models.auth.In;

/**
 * 角色token表
 *
 * @author Yun
 * @email Yun@frontop.cn
 * @date 2022-10-19 15:41:15
 */
public interface TokenService extends IService<TokenEntity> {
    /**
     * 根据ID获取token
     * @param tokenId id
     * @return token
     */
    String getTokenById(Integer tokenId);

    /**
     * 根据对象获取Token
     * @param tokenEntity
     * @return 结果
     */
    Object getTokenByEntity(TokenEntity tokenEntity);

    /**
     * 移除缓存id
     * @param tokenId 缓存id
     */
    void  removeCache(Integer tokenId);
}

